
package requests

import (
	"github.com/goravel/framework/contracts/http"
	"github.com/goravel/framework/contracts/validation"
)

type WechatMessageRequest struct {

	Openid string `json:"openid" form:"openid"`

	Type string `json:"type" form:"type"`

	Result string `json:"result" form:"result"`

	AddTime string `json:"add_time" form:"add_time"`

}

func (r *WechatMessageRequest) Authorize(ctx http.Context) error {
	return nil
}

func (r *WechatMessageRequest) Rules(ctx http.Context) map[string]string {
	return map[string]string{

		"openid": "required",

		"type": "required",

		"result": "required",

		"add_time": "required",

	}
}

func (r *WechatMessageRequest) Messages(ctx http.Context) map[string]string {
	return map[string]string{}
}

func (r *WechatMessageRequest) Attributes(ctx http.Context) map[string]string {
	return map[string]string{}
}

func (r *WechatMessageRequest) PrepareForValidation(ctx http.Context, data validation.Data) error {
	return nil
}
